package com.train.system.api;

import com.train.common.resp.CommonResp;
import com.train.system.service.TrainCarriageService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class TrainCarriageApiImpl implements TrainCarriageApi {

    @Autowired
    private TrainCarriageService trainCarriageService;

    @Override
    public CommonResp getTrainCarriageListByTrainCodes(List<String> trainCodes) {
        return CommonResp.ok(trainCarriageService.getTrainCarriageListByTrainCodes(trainCodes));
    }
}
